package greetings

import (
	"flag"
	"fmt"
)

func FlagDemo() {

	//main函数执行时候的参数
	var version = flag.String("v", "version", "true表示1 false表示0")
	var port = flag.String("port", "2.0", "true表示1 false表示0")

	flag.Parse()
	fmt.Println("v value: ", *version)
	fmt.Println("port value: ", *port)
}
